package com.twu.biblioteca;

import com.twu.biblioteca.controller.LibraryController;
import com.twu.biblioteca.domain.Book;
import com.twu.biblioteca.domain.Movie;

public enum BibliotechaActions implements BibliotechaAction {
        withdrawBook {
            @Override
            public void execute(String parameter, LibraryController<Movie> movieController, LibraryController<Book> bookController) {
                bookController.withdrawItem(parameter);
            }
        },
        withdrawMovie {
            @Override
            public void execute(String parameter, LibraryController<Movie> movieController, LibraryController<Book> bookController) {
                movieController.withdrawItem(parameter);
            }
        },
        returnBook {
            @Override
            public void execute(String parameter, LibraryController<Movie> movieController, LibraryController<Book> bookController) {
                bookController.returnItem(parameter);
            }
        },
        returnMovie {
            @Override
            public void execute(String parameter, LibraryController<Movie> movieController, LibraryController<Book> bookController) {
                movieController.returnItem(parameter);
            }
        }
    }
